#pragma once

#include <context.hpp>
#include "cmsis/cbus.h"
#include "serial/serial.hpp"
#include "serial/unix.hpp"
#include "serial/win.hpp"

class Robot
{
public:
	Robot(Serial* serial);
	~Robot();

	bool connect();
	bool cmd(uint8_t pan, uint8_t tilt, uint8_t zoom, uint8_t fire);
	
protected:
	Serial* serial;
	CBus cbus;
	uint8_t cbuf[CBUS_BUF_LEN];
};